home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Eagles Nest BBS 5
/
Eagles_Nest_Mac_Collection_Disc_5.TOAST
/
Science & Religion
/
Culture20#5
/
Culture 5 of 9
/
©1988-91 CRI Inc.
/
stack.txt
< prev
Wrap
Text File
|
1992-08-18
|
26KB
|
731 lines
-- stack: in.
-- format: 10 (HyperCard 2)
-- flags: 0x1400 (can't peek)
-- protect password hash: 881254725
-- maximum user level: 5 (scripting)
-- window: Rect(x1=0, y1=323, x2=96, y2=483)
-- screen: Rect(x1=0, y1=0, x2=640, y2=480)
-- card dimensions: w=96 h=160
-- scroll: x=0 y=0
-- background count: 1
-- first background id: 2778
-- card count: 1
-- first card id: 3027
-- list block id: 4632
-- print block id: 4008
-- font table block id: 3477
-- style table block id: 3314
-- free block count: 2
-- free size: 1472 bytes
-- total size: 32768 bytes
-- stack block size: 23040 bytes
-- created by hypercard version: 0x02006027
-- compacted by hypercard version: 0x02108000
-- modified by hypercard version: 0x02108000
-- opened by hypercard version: 0x02108000
-- patterns[0]: 0x0000000000000000
-- patterns[1]: 0x8000000008000000
-- patterns[2]: 0x8800220088002200
-- patterns[3]: 0x8888222288882222
-- patterns[4]: 0x88AA22AA88AA22AA
-- patterns[5]: 0xCCAA33AACCAA33AA
-- patterns[6]: 0xEEAABBAAEEAABBAA
-- patterns[7]: 0xEEBBBBEEEEBBBBEE
-- patterns[8]: 0xFFBBFFEEFFBBFFEE
-- patterns[9]: 0xFFBBFFFFFFBBFFFF
-- patterns[10]: 0x8010022001084004
-- patterns[11]: 0xFFFFFFFFFFFFFFFF
-- patterns[12]: 0x8822882288228822
-- patterns[13]: 0x1122448811224488
-- patterns[14]: 0xC4800C6843023026
-- patterns[15]: 0xB130031BD8C00C8D
-- patterns[16]: 0xAA00AA00AA00AA00
-- patterns[17]: 0x8822552288225522
-- patterns[18]: 0x8855225588552255
-- patterns[19]: 0x77DD77DD77DD77DD
-- patterns[20]: 0x8000000000000000
-- patterns[21]: 0xAA55AA55AA55AA55
-- patterns[22]: 0x038448300C020101
-- patterns[23]: 0x8244394482010101
-- patterns[24]: 0x8814224188412214
-- patterns[25]: 0x8080413E080814E3
-- patterns[26]: 0x22048C7422179810
-- patterns[27]: 0xBE808808EB088880
-- patterns[28]: 0x25C8328964244C92
-- patterns[29]: 0xA29C41BE2AC914EB
-- patterns[30]: 0x40A00000040A0000
-- patterns[31]: 0x8040200002040800
-- patterns[32]: 0xAA00800088008000
-- patterns[33]: 0xFF80808080808080
-- patterns[34]: 0x081C22C180010204
-- patterns[35]: 0xFF808080FF080808
-- patterns[36]: 0xF87422478F172271
-- patterns[37]: 0xBF00BFBFB0B0B0B0
-- patterns[38]: 0xFF7FBE5DA2418000
-- patterns[39]: 0xFAF5FAF5A050A050
-- checksum: 0xA4EA34A2
----- HyperTalk script -----
-- T H I S S T A C K I S P R O T E C T E D B Y F E D E R A L C O P Y R I G H T L A W S
-- A N Y U N A U T H O R I Z E D U S E (OR MODIFICATION) I S S T R I C T L Y
-- P R O H I B I T E D
-------------------------------------------------------------------------------------------------
-- This software has been licensed to CRI under 3/19/90 AI/CRI Agreement
-- HyperTag™, Original Graphic Design, HyperTalk Programming -- and Stack Design © 1988-1992 Applied Imagination Inc. All Rights Reserved
-- Implemented by Thomas Tafuto - AI/Applied Imagination, Inc.
-- 64 Morton Street • 1B New York, NY 10014 TELE:212 645.7199 - FAX:212 645.7585 - LINK: AI
-------------------------------------------------------------------------------------------------
-- This Stack Incorporates a third party commercial XFCN
-- PopMenu XFCN © 1988 Appropriate Technology. All rights reserved.
-- PopMenu XFCN documentation © 1988 Kirk Scott. All rights reserved.
-------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------
-------------------------------------------------------------------------------------------------
on doMenu m
if m="Find..." then NavigationSearch
pass doMenu
end doMenu
on openStack
global masterLinkList,CultureStacks,externalLinkList,display
put "" into masterLinkList
put "" into externalLinkList
put "Culture® OverView,Cultural Almanac,Biblical History,Greece,Rome,Middle Ages (400-1400),Renaissance (1400-1600),Baroque (1600-1750),Classic (1750-1803),Romantic (1803-1912),20th Century (1912-1991),Discipline MacroView,Notes" into CultureStacks
if short name of this stack is in CultureStacks then
set textArrows to false
if the screenRect="0,0,512,342" then put "small" into Display
else put "large" into Display
if Display="large" then set loc of cd window to "48,79"
if "Period Navigation" is not in the windows
then palette "Period Navigation","0,-42"
if "Culture Tools" is not in the windows
then palette "Culture Tools", "272,-42"
if "Standard Navigation" is not in the windows
then palette "Standard Navigation", "447,-42"
if Display="small" then
set loc of cd window to "0,0"
set loc of window "Period Navigation" to "1,0"
set loc of window "Culture Tools" to "272,0"
set loc of window "Standard Navigation" to "447,0"
end if
end if
pass openStack
end openStack
on returnKey
global gFindWhat
if gFindWhat≠"" then find whole gFindWhat
else pass returnKey
end returnKey
on convertLinks
global masterLinkList,externalLinkList,CultureStacks
--repeat with s=1 to the number of items in CultureStacks
--go cd "HyperTags" of stack item s of CultureStacks
put word 1 of short name of this stack&&"HyperTag‚Ñ¢" into fileName
put "" into MasterLinkList --the master specification
--put "0" into totalLength --the length of the specification
--open file fileName
repeat
read from file fileName for 16384
put it after MasterLinkList
if length(MasterLinkList) = totalLength then exit repeat
else put length(MasterLinkList) into totalLength
end repeat
close file fileName
--put word 1 of short name of this stack&&"ExternalLinks" into fileName
--put "" into externalLinkList
--put "0" into totalLength --the length of the specification
--put "Loading External links for stack:"&"e&short name of this stack"e
--open file fileName
--repeat
--read from file fileName for 16384
--put it after externalLinkList
--if length(externalLinkList) = totalLength then exit repeat
--else put length(externalLinkList) into totalLength
--end repeat
-- close file fileName
--hide msg
setFlds
put masterLinkList into ConvertList
repeat with i=1 to (the number of lines in ConvertList)
put "1" into IndexLetter
set the cursor to busy
if line i of ConvertList="" then
delete line i of ConvertList
next repeat
end if
if char 1 of item 2 of line i of ConvertList is not in "a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,1,2,3,4,5,6,7,8,9"
then put "1" into IndexLetter
else put char 1 of item 2 of line i of ConvertList into IndexLetter
put line i of ConvertList
delete last item of line i of ConvertList
if the number of chars in fld ("Index-"&IndexLetter)<30000 then
put line i of ConvertList&return after fld ("Index-"&IndexLetter)
else put line i of ConvertList&return after fld ("Index-5")
end repeat
--go next
--go cd "Externals" of stack item s of CultureStacks
-- setFlds
--put externalLinkList into ConvertList
--repeat with i=1 to (the number of lines in ConvertList)
-- put "1" into IndexLetter
--set the cursor to busy
--if line i of ConvertList="" then
-- delete line i of ConvertList
-- next repeat
-- end if
-- if char 1 of line i of ConvertList is not in "a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,1,2,3,4,5,6,7,8,9"
-- then put "1" into IndexLetter
-- else put char 1 of line i of ConvertList into IndexLetter
-- put line i of ConvertList
-- if the number of chars in fld ("Index-"&IndexLetter)<30000 then
-- put line i of ConvertList&return after fld ("Index-"&IndexLetter)
-- else put line i of ConvertList&return after fld ("Index-5")
--end repeat
--LoadLinkFlds
--end repeat
end convertLinks
on LoadLinkFlds
global masterLinkList,externalLinkList
repeat with f=1 to 36
set cursor to busy
if fld f of cd HyperTags≠"" then put fld f of cd HyperTags after masterLinkList
end repeat
repeat with f=1 to 36
set cursor to busy
if fld f of cd Externals≠"" then put fld f of cd Externals after externalLinkList
end repeat
end LoadLinkFlds
on setFlds
repeat with f=1 to 36
set cursor to busy
set rect of fld f to rect of fld 10
set textStyle of fld f to textStyle of fld 10
set textFont of fld f to textFont of fld 10
set textSize of fld f to textSize of fld 10
set textHeight of fld f to "10"
put "" into fld f
end repeat
end setFlds
on IndexSetUp
global CurrentIndex
repeat with f=1 to 35
hide bg fld F
set the hilite of bg btn f to false
end repeat
show bg fld "Index-A"
set the hilite of bg btn "A" to true
put "A" into CurrentIndex
end IndexSetUp
On SwitchDex Targ,TargID,TargName
global CurrentIndex
set hilite of targ to true
if not the visible of fld ("Index-"&targName) then
lock screen
set the hilite of bg btn CurrentIndex to false
hide bg fld ("Index-"&CurrentIndex)
set the visible of fld ("Index-"&targName) to true
set the scroll of fld ("Index-"&targName) to 0
put targName into CurrentIndex
set the hilite of targ to true
end if
unlock screen with visual dissolve
end SwitchDex
on BtnToCdLink
visual zoom open fast
go cd short name of target
if the result≠"" then answer "Currently, there is no card:"&return"e&short name of target"e
end BtnToCdLink
on AddThisToMasterList
--48758|Baroque (1600-1750)|cantata,
push cd
put selection into LinkTextTo
put word 3 of the id of this cd into Cdid
put short name of this stack into LinkedStack
go stack HyperTagLinker
ask "Type (or paste) text to link to your last selection…"
put it into TextLink
put TextLink&","&Cdid&"|"&LinkedStack&"|"&LinkTextTo&","&return after cd fld 1
pop cd
end AddThisToMasterList
on videoPopUp
global externalLinkList
put script of target into list
delete line 1 to 3 of list
put (the number of lines in list)/2 into PopHere
changeCurs 7
get PopMenu (bottom of target+1,left of target+1,PopHere,list)
if it = empty then answer "Hold mouse button down for a menu of images…"
else
if item 4 of it≠"-" and item 4 of it≠"" then
--if item 3 of it="1" then answer "This is the artist's name…"
--else
if externalLinkList="" then LoadLinkFlds
put item 4 of it into Image
get find(externalLinkList,Image,"item","exact")
put item 1 of it into returnLine
put item 2 of line returnLine of externalLinkList into theStartFrame
if the number of items in line returnLine of externalLinkList="3" then
put item 3 of line returnLine of externalLinkList into theEndFrame
video play,theStartFrame,theEndFrame
else video search,theStartFrame -- Uncomment this line for disc link
put theStartFrame&&theEndFrame
end if
end if
end videoPopUp
on CDPopUp
global externalLinkList
put script of target into list
delete line 1 to 3 of list
put (the number of lines in list)/2 into PopHere
changeCurs 7
get PopMenu (bottom of target+1,left of target+1,PopHere,list)
if it = empty then answer "Hold mouse button down for a menu of images…"
else
if item 4 of it≠"-" and item 4 of it≠"" then
--if item 3 of it="1" then answer "This is the artist's name…"
--else
if externalLinkList="" then LoadLinkFlds
put item 4 of it into Title
get find(externalLinkList,Title,"item","exact")
put item 1 of it into returnLine
put item 2 of line returnLine of externalLinkList into theTrack
if the number of items in line returnLine of externalLinkList="3" then
put item 3 of line returnLine of externalLinkList into theEndTrack
CDPlayTrack theTrack,theEndTrack
else CDPlayTrack theTrack -- Uncomment this line for disc link
--CDPlayTrack trackNumber <,trackNumber>
end if
end if
end CDPopUp
on DoNewCard
put short name of this cd into PrevCardName
if last char of PrevCardName is in "0,1,2,3,4,5,6,7,8,9" then
add 1 to last char of PrevCardName
end if
type "N" with commandKey
ask "Type in name for this card…" with PrevCardName
set name of this cd to it
put it into fld "Card Name"
end DonewCard
on PopNav t,l,menuName
changeCurs 7
get PopMenu (t,l,0,"|r"&menuName)
if menuName="OverView" then put "Culture® OverView" into targStack
else if menuName="Intro" then put "Culture® OverView" into targStack
else if menuName="Biblical" then put "Biblical History" into targStack
else if menuName="Greece" then put "Greece" into targStack
else if menuName="Rome" then put "Rome" into targStack
else if menuName="MiddleAges" then put "Middle Ages (400-1400)" into targStack
else if menuName="Renaissance" then put "Renaissance (1400-1600)" into targStack
else if menuName="Baroque" then put "Baroque (1600-1750)" into targStack
else if menuName="Classic" then put "Classic (1750-1803)" into targStack
else if menuName="Romantic" then put "Romantic (1803-1912)" into targStack
else if menuName="Century" then put "20th Century (1912-1991)" into targStack
if it = empty then
visual zoom out
if menuName="Intro" then go cd Introduction of stack targStack
else
go cd 1 of stack targStack
visual dissolve
go cd targStack of stack targStack
end if
else
if item 4 of it≠"-" and item 4 of it≠"" then
put item 4 of it into targCard
if targStack is not in "Biblical History,Greece,Rome,Culture® OverView"
then delete last word of targCard
visual zoom open
go cd targCard of stack targStack
end if
end if
set hilitedbutton of window "Period Navigation" to false
end PopNav
on setRects
repeat with i=1 to the number of bg btns
if "externalLink" is in the script of bg btn i
then set the style of bg btn i to transparent
end repeat
end setRects
on externalLink
answer "Cool…"
end externalLink
on ShiftBtnLocs
repeat with i=1 to the number of cd btns
put the loc of cd btn i into theNewLoc
subtract 51 from item 1 of theNewLoc
set loc of cd btn i to theNewLoc
end repeat
end ShiftBtnLocs
--on videoMenu theDirection,t,l
put "Step,Timed Step…,-|(,Play,Slowest,Fast,-|(,Scan" into list
get PopMenu (t,l,0,list)
if it = empty then doVideo step,theDirection,true
else
if item 4 of it≠"-" or item 4 of it≠"" then
if item 4 of it="Timed Step…" then
ask "Please type in the interval at which you would like to step through the frames in this videodisc… (in seconds)" with "5"
if it ≠"" then
put it into Interval
repeat until the mouseClick
put "Stepping through videodisc w/"&Interval&&"second pauses, (Click to stop…)…"
go next
wait interval seconds
end repeat
hide msg
end if
else doVideo (item 4 of it),theDirection,true
end if
end if
end videoMenu
--on doVideo what,direction,link
if what≠"Stop" then push cd
video what,direction
end doVideo
on openCard
global CultureStacks,display
if short name of this stack is in CultureStacks then
if the number of this cd="1" and display="small" then hidePalettes
else showPalettes
if "Period Navigation" is not in the windows then openStack
if "Culture Tools" is not in the windows then openStack
if "Standard Navigation" is not in the windows then openStack
if short name of this cd is not in fld "Card Name"
then put short name of this cd into fld "Card Name"
hide fld "Card Name"
end if
if there is a bg fld "SubTopic" and "." is not in short name of this cd then select text of fld "SubTopic"
if short name of this bg="Essays" and short name of this stack is not in "Culture® OverView,Greece, Rome, Biblical History" then --
set name of bg btn id 183 to short name of this cd
if bg fld 2≠"" then
put bg fld 2 into Holder
repeat until "/" is not in holder
get offset ("/",holder)
if it≠0 then delete char 1 to it of holder
end repeat
set icon of bg btn id 183 to Holder
end if
if "General Essay" is in bg fld "SubTopic" then hide bg btn id 182
else show bg btn id 182
end if
pass openCard
end openCard
on hidePalettes
if "Period Navigation" is in the windows then hide window "Period Navigation"
if "Culture Tools" is in the windows then hide window "Culture Tools"
if "Standard Navigation" is in the windows then hide window "Standard Navigation"
end hidePalettes
on showPalettes
if "Period Navigation" is in the windows then show window "Period Navigation"
if "Culture Tools" is in the windows then show window "Culture Tools"
if "Standard Navigation" is in the windows then show window "Standard Navigation"
end showPalettes
on CompactAllStacks
global CultureStacks,performingSearch
repeat with i=1 to the number of items in CultureStacks
set the cursor to busy
go stack (item i of CultureStacks)
protect
put "Now Compacting stack:"&&short name of this stack
doMenu "Compact Stack"
end repeat
go home
answer "All BCAT Stacks have been compacted (optimized)."
end CompactAllStacks
on Navigate
put script of target into list
delete line 1 to 3 of list
changeCurs 7
get PopMenu (bottom of target+1,left of target+1,0,list)
if it = empty then
put short name of target into targStack
set the hilite of target to false
visual zoom out
go cd 1 of stack targStack
wait 30 ticks
visual dissolve
go cd targStack of stack targStack
else
if item 4 of it = "-" or item 4 of it = "" then exit Navigate
else
set the hilite of target to false
put short name of target into targStack
put item 4 of it into targCard
if short name of target is not in "Biblical History,Greece,Rome" then delete last word of targCard
visual zoom open
go cd targCard of stack targStack
end if
end if
end Navigate
on Essay
put script of target into list
delete line 1 to 3 of list
get PopMenu (bottom of target+1,left of target+1,0,list)
if it=empty then
answer "Hold the mouse down for a list of essays…"
exit essay
end if
if item 4 of it = "-" or item 4 of it = "" then exit Essay
put item 4 of it into targCard
visual zoom open very fast
go cd targCard
end Essay
on MacroView
put script of target into list
delete line 1 to 3 of list
changeCurs 7
get PopMenu (bottom of target+1,left of target,0,list)
if it = empty then
visual zoom out
put short name of target into targCard
go cd targCard of stack "Culture® OverView"
if the result is not empty then
lock screen
put targCard into temp
answer "No card exists for:" && targCard with Cancel or Create
if it = "Create" then
push card
go last cd of bg "Essays"
domenu New Card
set name of this cd to temp
put short name of target into bg fld 1
unlock screen with visual iris open
end if
end if
else
if item 4 of it = "-" or item 4 of it = "" or item 4 of it = "Empty" then exit MacroView
else
if item 2 of it‚â•"A" then
put item 4 of it into targCard
visual zoom open very fast
go cd targCard of stack "Culture® OverView"
if the result is not empty then
lock screen
put targCard into temp
answer "No card exists for:" && targCard with Cancel or Create
if it = "Create" then
push card
go last cd of bg "Essays"
domenu New Card
set name of this cd to temp
put targCard into bg fld 1
unlock screen with visual iris open
end if
end if
end if
end if
end if
end MacroView
on PopAlmanac t,l,menuName
changeCurs 7
get PopMenu (t,l,0,"|r"&menuName)
if it = empty then
visual zoom out
go stack "Cultural Almanac"
else if item 4 of it≠"-" and item 4 of it≠"" then
put item 4 of it into TheMonth
ask "Please type in the day you want to find…" with "15"
put it into theDay
repeat with i=1 to number of chars in theDay
if char i of theDay is not in "0123456789" then
type "Not a valid entry, use numerals only…"
end if
end repeat
visual dissolve
go cd (theDay&" "&theMonth) of stack "Cultural Almanac"
end if
set hilitedButton of window "Period Navigation" to false
end PopAlmanac
on closeStack
if the freeSize of me > 50480 then doMenu Compact Stack
end closeStack
on closebackground
---set icon of bg btn BookButton to BookButton
--if the short name of this bg="Essays" then
-- if the visible of bg btn "Return" then hide bg btn "Return"
--end if
end closebackground
on EnterKey
global CulturePath
if the CommandKey is down then
get offset(short name of this cd,CulturePath)
if it=0
then put the short name of this cd&" ["&short name of this stack&","&return after CulturePath
else answer "This card is already in the loaded Culture Path…"
exit EnterKey
end if
CompleteLink
end EnterKey
on CompletePathLink
global LinkStat,LinkFromCd,LinkFromStak,LinkToCd,LinkToStak
if LinkStat≠"true" then exit CompleteLink
put short name of this cd into LinkToCd
put short name of this stack into LinkToStak
visual zoom in
go cd LinkFromCd of stack LinkFromStak
put LinkToCd&" ["&LinkToStak&","&return into newScript
get script of this cd
set script of this cd to it&newScript
if the script of this cd≠"" then set hilite of bg btn Linker to true
put "" into LinkStat
end CompletePathLink
on Levels
set cursor to 4
if short name of this stack="Biblical History" then
visual zoom in
go cd (short name of target)
else if short name of target≠short name of this cd then
if short name of this bg="Essays" and the id of the target=182 then
put bg fld 1 into targCard
delete last word of targCard
else put short name of target into targCard
visual zoom in
go cd targCard
else
beep
answer "This button represents the current card:"&return&short name of this cd
end if
end Levels
on Notes
set userModify to false
set cursor to 4
if not the visible of bg fld id 122 then
lock screen
hide bg btn cover
show bg btn CloseBox
show bg btn "Do Reports…"
hide card picture
repeat with i=1 to number of bg btns
if "blackout" is in short name of bg btn i then show bg btn i
end repeat
repeat with i=1 to the number of card buttons
hide cd btn i
end repeat
show bg fld id 122
unlock screen with visual zoom open very fast
set userModify to true
exit Notes
end if
if the visible of bg fld id 122 then
set the scroll of bg fld id 122 to 0
lock screen
show cd picture
repeat with i=1 to the number of card buttons
show cd btn i
end repeat
repeat with i=1 to number of bg btns
if "blackout" is in short name of bg btn i then hide bg btn i
end repeat
if bg fld id 122 ≠"" then set the hilite of target to true
show bg btn cover
hide bg btn CloseBox
hide bg fld id 122
hide bg btn "Do Reports…"
unlock screen with visual zoom close very fast
end if
set userModify to true
end notes
on essayLinkage
set userModify to false
set cursor to 4
if not the visible of bg fld id 183 then
lock screen
hide cd picture
repeat with i=1 to the number of card buttons
hide cd btn i
end repeat
show bg fld id 183
unlock screen with visual zoom open very fast
set hilite of target to true
set userModify to true
exit essayLinkage
end if
if the visible of bg fld id 183 then
set the scroll of bg fld id 183 to 0
lock screen
if not the visible of bg fld id 122 then
show cd picture
repeat with i=1 to the number of card buttons
show cd btn i
end repeat
end if
hide bg fld id 183
set the hilite of target to true
unlock screen with visual zoom close very fast
end if
set userModify to true
end essayLinkage
on EssayLink
visual zoom out
go cd short name of target
end essayLink
on ExitCultureQuit
doMenu "Quit HyperCard"
end ExitCultureQuit
on ExitCultureHome
visual iris close
go home
end ExitCultureHome
--function lineClicked
return ((the mouseV - item 2 of the rect of the target) div the textHeight of the target) + 1
end lineClicked
--Function Clickline
return (trunc(((scroll of the target) + (item two of the clickloc) - (item two of the rect of the target)) div the textheight of the target) + one)
End Clickline
on GridLink
if the optionKey is down then
--answer "Chris, are you sure you want to delete this button?" with "Cancel" or "OK"
--if it is "OK" then
choose button tool
click at the loc of target
doMenu"Clear Button"
choose browse tool
-- end if
exit GridLink
end if
put bg fld CID&short name of target into targCard
visual zoom out
go cd targCard
if the result is not empty then
lock screen
put bg fld 1 into tem
put targCard into temp
answer "No card exists for:" && targCard with Cancel or Create
if it = "Create" then
put number of this cd into JumpBack
go last cd
domenu New Card
set name of this cd to temp
put tem into bg fld 1
put short name of target into bg fld 2
unlock screen with visual iris open
go cd jumpBack
end if
end if
end GridLink
on protect
repeat with i=1 to the number of cds
set cantDelete of cd i to true
end repeat
end protect